package njci.softerware.com.myexpress2017.serviceObj;

import android.os.Parcel;
import android.os.Parcelable;

import com.j256.ormlite.field.DatabaseField;
import com.j256.ormlite.table.DatabaseTable;

/**
 * Created by 徐连宝 on 2016/9/19.
 */

@DatabaseTable(tableName = "packageRecevie")
public class PackageRecevie implements Parcelable {

    /**
     * re_date : 16-09-18
     * count_recevie : 1
     * phone : 2355777
     * user_id : 16
     * NAME : admin
     * recevier_id : 16
     */
    @DatabaseField(columnName = "keyId", generatedId = true)
    private Integer keyId;

    @DatabaseField(columnName = "re_date")
    private String re_date;
    @DatabaseField(columnName = "count_recevie")
    private int count_recevie;
    @DatabaseField(columnName = "phone")
    private String phone;
    @DatabaseField(columnName = "user_id")
    private int user_id;
    @DatabaseField(columnName = "NAME")
    private String NAME;
    @DatabaseField(columnName = "recevier_id")
    private int recevier_id;


    public Integer getKeyId() {
        return keyId;
    }

    public void setKeyId(Integer keyId) {
        this.keyId = keyId;
    }

    public void setRe_date(String re_date) {
        this.re_date = re_date;
    }

    public void setCount_recevie(int count_recevie) {
        this.count_recevie = count_recevie;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public void setUser_id(int user_id) {
        this.user_id = user_id;
    }

    public void setNAME(String NAME) {
        this.NAME = NAME;
    }

    public void setRecevier_id(int recevier_id) {
        this.recevier_id = recevier_id;
    }

    public String getRe_date() {
        return re_date;
    }

    public int getCount_recevie() {
        return count_recevie;
    }

    public String getPhone() {
        return phone;
    }

    public int getUser_id() {
        return user_id;
    }

    public String getNAME() {
        return NAME;
    }

    public int getRecevier_id() {
        return recevier_id;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.getKeyId());
        dest.writeString(this.re_date);
        dest.writeInt(this.count_recevie);
        dest.writeString(this.phone);
        dest.writeInt(this.user_id);
        dest.writeString(this.NAME);
        dest.writeInt(this.recevier_id);
    }

    public PackageRecevie() {
    }

    protected PackageRecevie(Parcel in) {
        this.keyId = in.readInt();
        this.re_date = in.readString();
        this.count_recevie = in.readInt();
        this.phone = in.readString();
        this.user_id = in.readInt();
        this.NAME = in.readString();
        this.recevier_id = in.readInt();
    }

    public static final Parcelable.Creator<PackageRecevie> CREATOR = new Parcelable.Creator<PackageRecevie>() {
        public PackageRecevie createFromParcel(Parcel source) {
            return new PackageRecevie(source);
        }

        public PackageRecevie[] newArray(int size) {
            return new PackageRecevie[size];
        }
    };
}
